#ifndef __DIGIMON_API_H__
#define __DIGIMON_API_H__

/******************** 对外接口 *********************/

#include <stdint.h>
#include <stdio.h>
#include <stdlib.h>

#define DIGI_NAMELEN 20
#define DIGIMON_Y    6

/******* config ********/
#define DIGIMON_BMP_SIZE_16
/* size of digimon bmp 16*16 */
#ifdef DIGIMON_BMP_SIZE_16
#define DIGIMON_W 16
#define DIGIMON_H 2 //DIGIMON_W/8
#endif

typedef unsigned char uchar;
typedef void digimon_t;
typedef struct digimon_api_st
{
    digimon_t *(*digimon_create)(uint8_t digiType, digimon_t **digi);
    void (*digimon_alive)(digimon_t *digi);
    void (*digimon_display)(digimon_t *digi, uint8_t m_tiki);        /* 鍦ㄥ睆骞曚笂鎻忕粯涓?鍙猟igimon */
    void (*digimon_menu)(uint8_t index);   /* 缁樺埗绯荤粺鍥炬�? */
    void (*show_sys_aixin)(uint8_t current);/* 缁樺埗鐖卞績 */
    void (*system_digimon_info)(uint8_t page);
    uint8_t (*digimon_eat)(digimon_t *digimon, uint8_t food);
    void (*show_shirt)(uint8_t m_tiki);     /* 缁樺埗澶т�? */
    void (*show_ill)(void); 
    void (*show_no)(void);               /* 缁樺埗鐢熺梾 */
    void (*digimon_dump)(digimon_t *digi);
    int  (*init_digimon_bmps)(uint16_t id, uchar (*bmps)[DIGIMON_W][DIGIMON_H]);
}digimon_api;
extern digimon_api digi_api;




#endif
